﻿using Microsoft.EntityFrameworkCore.Metadata.Internal;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace S.Authorization.Domain.Model.Organization
{
    /// <summary>
    /// 栏位表
    /// </summary>
    [Table("FieldModel")]
    public class FieldModel
    {
        [Key]
        ///主键
        public int ColumnManagementId { get; set; }

        /// <summary>
        /// 栏位名称（唯一）
        /// </summary>
        [Column(TypeName = "nvarchar(50)")]
        [MaxLength(50)]
        public string ColumnName { get; set; }

        /// <summary>
        /// 前缀
        /// </summary>
        [Column(TypeName = "nvarchar(50)")]
        [MaxLength(50)]
        public string? Prefix { get; set; }

        /// <summary>
        /// 主键栋舍
        /// </summary>
        public int BuildingManagementId { get; set; }

        /// <summary>
        /// 栋舍类型（下拉框）
        /// </summary>
        public int BuildingTypes { get; set; }

        /// <summary>
        /// 负责人（用于以负责人维度汇总栋舍绩效使用）
        /// </summary>
        [Column(TypeName = "nvarchar(50)")]
        [MaxLength(50)]
        public string? ResponsiblePerson { get; set; }
    }
}
